<extend name="CommonAdmin:base" />

<block name="script">
<script>
$(function() {
   $("#list").tablesorter({ theme : 'blue' });
   $("button.update").button({
       icons: {
         primary: "ui-icon-pencil"
       },
       text: false
   });
   $("button.delete").button({
       icons: {
         primary: "ui-icon-trash"
       },
       text: false
   });
   $("button.create").button({
       icons: {
         primary: "ui-icon-document"
       }
   });
});
function update(id) {
    var url = "__URL__/update/id/" + id;
    window.location = url;
}
function del(id) {
    var url = "__URL__/delete/id/" + id;
    window.location = url;
}
function create() {
    var url = "__URL__/create";
    window.location = url;
}
</script>
</block>

<block name="main-in">
<div class="toolbar ui-widget-header ui-corner-all">
<button class="create" onclick="create()">新建</button>
</div>

<div style="width: 100%">
<table id="list" class="tablesorter" border="0" cellpadding="0" cellspacing="1">
    <thead>
        <tr>
            <th nowrap>公司名称</th>
            <th nowrap>商品名称</th>
            <th nowrap>类别</th>
            <th nowrap>是否销售</th>
            <th nowrap>编码</th>
            <th nowrap>用户</th>
            <th nowrap>点击数</th>
            <th nowrap>是否最好的</th>
            <th nowrap>是否新品</th>
            <th nowrap>是否特殊</th>
            <th nowrap>是否特价</th>
            <th nowrap>关键字</th>
            <th nowrap>摘要</th>
            <th nowrap>内容</th>
            <th nowrap>市场价</th>
            <th nowrap>在售价</th>
            <th nowrap>单位</th>
            <th nowrap>发布时间</th>
            <th nowrap>公开价</th>
            <th nowrap>权限</th>
            <th nowrap>是否评论</th>
            <th nowrap>商品模版</th>
            <th nowrap>修改</th>
            <th nowrap>创建</th>
            <th nowrap>操作</th>
        </tr>
    </thead>
    <tbody></tbody>
    <volist name="list" id="vo">
    <tr>
        <td>{$vo.companyname}</td>
        <td>{$vo.goodsname}</td>
        <td>{$vo.sortname}</td>
        <td>{$vo.is_sell}</td>
        <td>{$vo.code}</td>
        <td>{$vo.nickname}</td>
        <td>{$vo.hits}</td>
        <td>{$vo.isbest}</td>
        <td>{$vo.isnew}</td>
        <td>{$vo.ishot}</td>
        <td>{$vo.isspecial}</td>
        <td>{$vo.keywords}</td>
        <td>{$vo.brief}</td>
        <td>{$vo.content}</td>
        <td>{$vo.marketprice}</td>
        <td>{$vo.shopprice}</td>
        <td>{$vo.unit}</td>
        <td>{$vo.publishtime}</td>
        <td>{$vo.publishopt}</td>
        <td>{$vo.alowpower}</td>
        <td>{$vo.iscomment}</td>
        <td>{$vo.goodstpl}</td>
        <td>{$vo.modification}</td>
        <td>{$vo.created}</td>
        <td>
        <button class="update" onclick="update('{$vo.id}')">查看/修改</button>
        <button class="delete" onclick="del('{$vo.id}')">删除</button>
        </td>
    </tr>
    </volist>
</table>
</div>
</block>